import LightKV from "lightkv";
/**
 * {
 *    rooms: IRoom[],
 *    managers: IUser[]
 * }
 */
export const dataDB = new LightKV('rooms.lkv', 'c+', LightKV.OBJECT);


/**
 * {
 *    [room_id]: [
 *        {
 *          date: '2021-08-12',
 *          messages: [
 *            {
 *               time: '08:03:34',
 *               value: '打开了空调'
 *            }
 *          ]
 *        }
 *      ] 
 *    }
 * }
 */
export const logDB = new LightKV('log.lkv', 'c+', LightKV.OBJECT);